﻿using UnityEngine;
using System.Collections;
using FrenzyIsland.UI;

public class BuildingMenuCtrl : MonoBehaviour {

    private GameObject uiroot;
    private GuiManager guiManager;

    void Awake()
    {
        uiroot = GameObject.FindGameObjectWithTag("UI");
        guiManager = uiroot.GetComponent<GuiManager>();
    }

	// Use this for initialization
	void Start () {
	
	}
	
	// Update is called once per frame
	void Update () {
	
	}

    public void ItemClick(GameObject gameobject)
    {
        Debug.Log("Ho cliccato " + gameobject.GetComponent<UIBuildingItem>().type.ToString());
    }

    public void CloseThis()
    {
        //guiManager.CloseMenu(this.gameObject);
    }

}
